<?php

class Administration_QuestionController extends Zend_Controller_Action
{

    public function init()
    {
        /* Initialize action controller here */
    }

    public function indexAction()
    {
        // action body
    }

    public function addAction()
    {
        $this->view->data = $this->_request->getParam('id');
        $model_model = new Administration_Model_Question();
        $i=$this->_request->getParam('ind');
        $x=1;
         

        while($x <=$i){
         $q=$this->_request->getParam('q'.$x);
         $a=$this->_request->getParam('a'.$x);
         $b=$this->_request->getParam('b'.$x);
         $c=$this->_request->getParam('c'.$x);
         $d=$this->_request->getParam('d'.$x);
         $corr=$this->_request->getParam('corr'.$x);
                 // $button=$this->_request->getParam('button');
                  
         ///$button.disabled = true;
         $model_model->addQuestion($q,$a,$b,$c,$d,$corr,  $this->_request->getParam('id'));
         $x++;  
        }
    }


}



